<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateLoginPermissionsTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('login_permissions', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('wxuser_id')->comment('微信编号');
            $table->integer('login_type_id')->nullable()->comment('登陆权限');
            $table->tinyInteger('status')->nullable()->default(1)->comment('用户登陆状态');
            $table->timestamps();
            $table->softDeletes();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('login_permissions');
    }
}
